<?php

class Controller_Dashboard extends Controller_Abstract
{
	function actionShow(){
		if($this->_view['isAdmin']){
			return $this->_redirect(url('dashboard/admin'));
		}elseif($this->_view['isPublisher']){
			return $this->_redirect(url('dashboard/publisher'));
		}elseif($this->_view['isGameco']){
			return $this->_redirect(url('dashboard/cgb'));
		}elseif($this->_view['isReadonly']){
			return $this->_redirect(url('dashboard/readonly'));
		}else{
			return $this->_redirect(url('dashboard/market'));
		}
	}
	
	function actionCgb(){
		$fmodel = new Fulfillment();
		$this->_view['pendingFulfillments'] = $fmodel->getPendingFulfillments();
		$dmodel = new Dashboard();
		$this->_view['sites'] = $dmodel->cgbDashboard();
	}
	
	function actionMarket(){
		$dmodl = new Dashboard();
	}
	
	function actionPublisher(){
		Q::loadFile('TimeUtil.php', Helper_Dir);
		$dmodl = new Dashboard();
	}
	
	function actionAdmin(){
		$dmodl = new Dashboard();
	}
	
	function actionReadonly(){
		$dmodl = new Dashboard();
	}
}

?>